import request from '@/utils/request'

export function download(data) {
  return request({
    url: `/download/${data.fileType}/${data.fileName}`,
    method: 'get',
    responseType: 'blob'
  })
}

export function downloadTxt(data) {
  return request({
    url: '/download/file',
    method: 'get',
    responseType: 'text',
    params: data
  })
}

export function getFileList() {
  return request({
    url: '/file/list',
    method: 'get'
  })
}